export type Align = "left" | "right";
export type Size = "small" | "regular" | "large";
export type Placement = "left" | "right" | "center";

// 使用递归实现枚举
export type Enumerate<
  N extends number,
  Acc extends number[] = []
> = Acc["length"] extends N
  ? Acc[number]
  : Enumerate<N, [...Acc, Acc["length"]]>;

export type Brightness = Enumerate<256>;

export type RGB = `rgb(${number}, ${number}, ${number})`;
export type RGBA = `rgba(${number}, ${number}, ${number}, ${number})`;
export type HSL = `hsl(${number}, ${number}%, ${number}%)`;
export type HSLA = `hsla(${number}, ${number}%, ${number}%, ${number})`;
export type HEX = `#${string}`;
export type CSSVar = `var(--${string})`;

export type CSSColor = HEX | RGB | RGBA | HSL | HSLA | CSSVar;
